package com.young.job;

import java.io.Serializable;
import java.util.Objects;

/**
 * @description：server 端节点信息
 * @author: yangyahui01
 * @date: 11/25/24 2:53 PM
 */
public class ScheduleServerInstanceDO implements Serializable {

    private String ip;

    private int port;

    public String getIp() {
        return ip;
    }

    public void setIp(String ip) {
        this.ip = ip;
    }

    public int getPort() {
        return port;
    }

    public void setPort(int port) {
        this.port = port;
    }

    @Override
    public int hashCode() {
        return Objects.hash(ip,port);
    }

    @Override
    public boolean equals(Object obj) {
        return obj.hashCode() == this.hashCode();
    }

    @Override
    public String toString() {
        return "{ip:" + ip + ",port:" + port + "}";
    }
}
